﻿using System;
using System.Collections.Generic;
using System.Text;
using T.FAS.Runtime.Metadata.Entity;

namespace T.FAS.Runtime.Metadata.SPI
{
    /// <summary>
    /// 元数据发布管理接口
    /// </summary>
    public interface IMetaDataReleaseManager
    {
        /// <summary>
        /// 冲突检查
        /// </summary>
        /// <param name="releasedMetaData">已发布的元数据</param>
        /// <param name="releaseingMetaData">将要发布的元数据</param>
        /// <returns>冲突检查结果</returns>
        ConflictMessage ConflictCheck(List<IMetaDataContent> releasedMetaData, IMetaDataContent releaseingMetaData);

        /// <summary>
        /// 导出
        /// </summary>
        /// <param name="metaDataList">元数据</param>
        /// <returns>元数据导出结果</returns>
        IList<MetaDataExportContent> Export(params IMetaDataContent[] metaDataList);

        /// <summary>
        /// 导入
        /// </summary>
        /// <param name="contents">元数据导出结果</param>
        /// <param name="importStrategy">导入策略</param>
        void Import(IList<MetaDataExportContent> contents, MetaDataImportStrategy importStrategy);

        /// <summary>
        /// 元数据启用
        /// </summary>
        /// <param name="metaData">元数据集合</param>
        void Enable(params IMetaDataContent[] metaData);
    }
}
